package com.xhsj.user.hr.process.hrBecomeRegular.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xhsj.user.hr.process.dto.hrBecomeRegular.MyBecomeRegularApplyListDto;
import com.xhsj.user.hr.process.dto.hrBecomeRegular.RunBecomeRegularApplyListDto;
import com.xhsj.user.hr.process.hrBecomeRegular.query.*;
import com.xhsj.user.hr.system.vo.MonthCountVo;
import org.apache.ibatis.annotations.Mapper;
import com.xhsj.user.hr.process.hrBecomeRegular.entity.TbHrApprovalBecomeRegularApply;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * <p>
 * hr流程_转正申请表 Mapper 接口
 * </p>
 *
 * @author liuqinghua
 * @since 2020-09-10
 */
@Mapper
public interface TbHrApprovalBecomeRegularApplyMapper extends BaseMapper<TbHrApprovalBecomeRegularApply> {

    /**
     * 获取用户要转正申请得数据
     * @author liuqinghua
     * @date Sep 10, 2020 3:48:00 PM
     */
    BecomeRegularDataQuery getBecomeRegularData(@Param("userId") Long userId);

    /**
     * 我的转正申请列表
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    IPage<MyBecomeRegularApplyListQuery> myBecomeRegularApplyList(Page<MyBecomeRegularApplyListQuery> page,
                                                                  @Param("data") MyBecomeRegularApplyListDto data,
                                                                  @Param("userId") Long userId);

    /**
     * 待审核转正申请列表
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    IPage<RunBecomeRegularApplyListQuery> runBecomeRegularyApplyList(Page<RunBecomeRegularApplyListQuery> page,
                                                                     @Param("data") RunBecomeRegularApplyListDto data,
                                                                     @Param("userId") Long userId,
                                                                     @Param("roleList") List<Long> roleList);

    /**
     * 已审核转正申请列表
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    IPage<CompletedBecomeRegularApplyQuery> completedBecomeRegularApplyList(Page<CompletedBecomeRegularApplyQuery> page,
                                                                            @Param("userId") Long userId,
                                                                            @Param("data") RunBecomeRegularApplyListDto data);
    /**
     * 基本信息
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    MyBecomeRegularBaseDetailedListQuery getMyBecomeRegularBaseDetailedList(@Param("dataId") Long dataId);

    /**
     * 全部转正申请列表
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    IPage<MyBecomeRegularApplyListQuery> allBecomeRegularApplyList(Page<MyBecomeRegularApplyListQuery> page,
                                                                   @Param("data") MyBecomeRegularApplyListDto data);

    /**
     * 我的转正申请详细信息之评审分数
     * @author liuqinghua
     * @date Sep 1, 2020 10:07:11 AM
     */
    List<MyBecomeRegularApplyDetailedListScoreQuery> myBecomeRegularApplyDetailedListScore(@Param("dataId") Long dataId);

    /**
     * 查询每月转正人数
     * @author 苏小林
     * @date 2020/9/14 16:00
     * @param: date
     * @return: java.util.List<com.xhsj.user.hr.system.vo.MonthCountVo>
     */
    List<MonthCountVo> getCountByDate(@Param("date") String date);
    /**
     * @Description:  查询当月入职人数-截至到今天
     * @Author: liuqinghua
     * @Date: 2021/9/9
     */
    MonthCountVo getCunrrentCountByDate();
}
